package com.web.entity;

import com.baomidou.mybatisplus.annotation.*;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;

import java.io.Serializable;
import java.util.Date;

@Data
@TableName("user_info")
public class UserInfo implements Serializable{
    @TableId(type = IdType.AUTO,value = "id")
    private Integer id;

    @TableField(value = "address")
    private String address;

    @TableField(value = "user_id")
    private Integer userId;

    @TableLogic
    private Integer deleted;

    @TableField(fill = FieldFill.INSERT)
    private Date createTime;

    @JsonFormat(locale = "zh", timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    private Date updateTime;

    @TableField(exist = false)
    private User user;


//    public void setUser(User user){
//        this.user = user;
//    }
//
//    public User getUser(){
//        return user;
//    }

}
